import req from './http';
export function login(obj) {
  return req.post('login', {
    ...obj
  })
}
export function getMenus(obj) {
  return req.get('menus')
}
//获取用户列表
export function getUserList(queryInfo) {
  return req.get('users', {
    params: queryInfo
  })
}
//更新用户状态
export function changeUserStatus(row) {
  return req.put(`users/${row.id}/state/` + row.mg_state)
}
//更新用户状态  
export function deleteUser(id) {
  return req.delete('users/' + id)
}
//获取角色列表 
export function getRoles() {
  return req.get('roles')
}
//获取所有权限列表
export function getRights() {
  return req.get('rights/list')
}
//获取商品列表
export function getGoods(queryInfo) {
  return req.get('goods', {
    params: queryInfo
  })
}

